package leetcode.array;

import leetcode.array.common.ArrayUtils;

class Solution121 {
    public int maxProfit(int[] prices) {
        return ArrayUtils.maxProfit(prices);
    }
}

public class leetcode121 {
    public static void main(String[] args) {
        Solution121 solution121 = new Solution121();
        int[] nums = {7,1,5,3,6,4};
        int[] nums1 = {7,6,4,3,1};
        System.out.println(solution121.maxProfit(nums));
        System.out.println(solution121.maxProfit(nums1));
    }
}
